package edu.hawaii.ics.pjdb.partition_function;

import java.util.ArrayList;
import java.util.List;

import edu.hawaii.ics.pjdb.types.Tuple;

public interface PartitionFunction {
    /**
     * Partitions the given tuples using the class-specific partitioning
     * function on the given index.
     * 
     * @param tuples
     *            The Tuples to be partitioned.
     * @param arguments
     *            The arguments needed by the partitioning function (if any).
     * @param partitionFieldIndex
     *            The index of the field on which to apply the partitioning
     *            function.
     * @return The partitioned Tuples.
     */
    public abstract ArrayList<ArrayList<Tuple>> partition(List<Tuple> tuples,
            List<String> arguments, Integer partitionFieldIndex);
}
